package com.ruoyi.pv.domain;

import com.doudou.core.lang.ObjUtil;
import lombok.*;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 用户信息表对象 pv_user_info
 *
 * @author zzx
 * @date 2023-06-07
 */
@AllArgsConstructor
@NoArgsConstructor
@Data
@Builder
@ToString
public class PvUserInfo extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /**
     * 学生编号
     */
    private Long id;

    /**
     * 工作单位
     */
    @Excel(name = "工作单位")
    private String workUnit;

    /**
     * 社区
     */
    @Excel(name = "社区")
    private String community;

    /**
     * 执业范围
     */
    @Excel(name = "执业范围")
    private String practiceRange;

    /**
     * 执业类别
     */
    @Excel(name = "执业类别")
    private String practiceType;

    /**
     * 所在科室/岗位
     */
    @Excel(name = "所在科室/岗位")
    private String posts;

    /**
     * 参加初训年份
     */
    @Excel(name = "参加初训年份")
    private String initialTraining;

    /**
     * 备注
     */
    @Excel(name = "备注")
    private String docNumber;

    /**
     * 证件号
     */
    @Excel(name = "证件号")
    private String comment;

    /**
     * 预留字段1
     */
//    @Excel(name = "初复训" ,readConverterExp = "0=初训,1=复训")
    private String reservedOne;

    /**
     * 预留字段2
     */
    @Excel(name = "预留字段2")
    private String reservedTwo;


    public Boolean isFirst(){
        return "0".equals(this.reservedOne);
    }

    public Boolean isEmpty(){
        return ObjUtil.isNull(this.workUnit)
                && ObjUtil.isNull(this.community)
                && ObjUtil.isNull(this.practiceRange)
                && ObjUtil.isNull(this.practiceType)
                && ObjUtil.isNull(this.posts)
                && ObjUtil.isNull(this.initialTraining)
                && ObjUtil.isNull(this.docNumber)
                && ObjUtil.isNull(this.comment)
                && ObjUtil.isNull(this.reservedOne)
                && ObjUtil.isNull(this.reservedTwo)
                && ObjUtil.isNull(getCreateTime());
    }

}
